package com.sc.nft.vo.redeemcard;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.sc.nft.enums.RedeemCardValidityEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * @author JYT
 * @create 2024/5/7 15:53
 */
@Data
public class RedeemCardPageVO {
    @JsonSerialize(using = ToStringSerializer.class)
    private Long id;
    /**
     * 商品标题
     */
    @ApiModelProperty(value = "商品标题")
    private String title;
    /**
     * 商品封面
     */
    @ApiModelProperty(value = "商品封面")
    private String img;
    /**
     * 是否上架
     */
    @ApiModelProperty(value = "是否上架")
    private Boolean isOpen;
    /**
     * 有效时间
     */
    @ApiModelProperty(value = "有效时间 FOREVER 永久有效, AFTER_DAY 从获得开始多少天内有效")
    private RedeemCardValidityEnum validity;
    /**
     * 有效天数
     */
    @ApiModelProperty(value = "有效天数")
    private Integer validityDay;
    /**
     * 创建时间
     */
    @ApiModelProperty(value = "创建时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

}
